package com.linkoog.devtools.http.request.common.response_body;

import com.linkoog.devtools.http.request.common.ResponseBody;
import com.linkoog.devtools.http.request.common.ResponseBodyType;
import lombok.Getter;
import lombok.Setter;

@Setter @Getter
public class ErrorResponseBody implements ResponseBody {

    protected String value;

    public ErrorResponseBody() {
    }

    public ErrorResponseBody(String value) {
        this.value = value;
    }

    public static ErrorResponseBody of(String value) {
        return new ErrorResponseBody(value);
    }

    @Override
    public ResponseBodyType bodyType() {
        return ResponseBodyType.ERROR;
    }

    @Override
    public String toString() {
        return "ErrorResponseBody{" +
                "value='" + value + '\'' +
                '}';
    }
}
